package com.all.diy;
import android.app.Application;
import android.content.Context;
import com.blankj.utilcode.util.Utils;
import me.jessyan.autosize.AutoSize;
import me.jessyan.autosize.AutoSizeConfig;

/**
 * Created by MaYangHua on 2020/7/03.
 * email : 295965650@qq.com
 */
public class CustomApplication extends Application {
    public static CustomApplication sApplication;

    @Override
    public void onCreate() {
        super.onCreate();
        if (sApplication == null) {
            sApplication = this;
        }
        AutoSize.initCompatMultiProcess(this);
        Utils.init(this);
        // 配置AutoSize参数
        AutoSizeConfig.getInstance()
                .setCustomFragment(true)
                .setUseDeviceSize(false)
                .setBaseOnWidth(true)
                .setLog(true);
    }

    @Override
    protected void attachBaseContext(Context base) {
        super.attachBaseContext(base);
    }

}
